package kgame5.k3d.core.math.func {
import kgame5.k3d.core.math.Vector3D;

/**
 * @author kk
 * 直线的 公式
 * P(t)=P0+t*D 注意大写字母为向量
 */
public class LineFunc {
	private var temp:Vector3D=new Vector3D();
	private var pt:Vector3D=new Vector3D();
	public var P0:Vector3D;
	public var D:Vector3D;
	
	//根据给定参数计算出值
	public function func(t:Number):Vector3D{
		Vector3D.SMul(D, t, temp);
		Vector3D.SAdd(P0,temp , pt);
		return pt;
	}
}
}
